package example;

import models.CategoryModel;
import data.CategoryData;

public class CategoryExample {
	public static void create() {
		CategoryData cData = new CategoryData();
		CategoryModel category = new CategoryModel();
		
		category = new CategoryModel();
		category.setId(new Long(1));
		category.setName("category 1");
		cData.insert(category);
		
		category = new CategoryModel();
		category.setId(new Long(2));
		category.setName("category 2");
		cData.insert(category);
		
		category = new CategoryModel();
		category.setId(new Long(3));
		category.setName("category 3");
		cData.insert(category);
		
		category = new CategoryModel();
		category.setId(new Long(4));
		category.setName("category 4");
		cData.insert(category);
		
		category = new CategoryModel();
		category.setId(new Long(5));
		category.setName("category 1-1");
		category.setParentId(1);
		cData.insert(category);
		
		category = new CategoryModel();
		category.setId(new Long(6));
		category.setName("category 1-2");
		category.setParentId(1);
		cData.insert(category);
		
		category = new CategoryModel();
		category.setId(new Long(7));
		category.setName("category 1-1-1");
		category.setParentId(5);
		cData.insert(category);
		
	}
}
